package com.ruoyi.zhgd.mapper;

import com.ruoyi.common.core.mapper.BaseMapperPlus;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * 首页Mapper接口
 */
public interface ZjHomeMapper extends BaseMapperPlus{

    List<String> getDeptListByLevel();
    List<String> getSubDeptList(String deptId);

    /**
     * 首页接入设备及预警统计
     * @return
     */
    List<Map<String,Object>> count();

    /**
     * 首页-拌合站今日生产统计
     * @return
     */
    List<Map<String, Object>> productToday(@Param("list") List<String> deptIdList);

    /**
     * 首页-拌合站产能统计
     * @param params
     * @return
     */
    List<Map<String, Object>> productYear(Map<String, Object> params);

    /**
     * 按周查询一标
     * @return
     */
    List<Map<String, Object>> productWeek1();

    /**
     * 按周查询二标
     * @return
     */
    List<Map<String, Object>> productWeek2();

    /**
     * 按周查询三标
     * @return
     */
    List<Map<String, Object>> productWeek3();

    /**
     * 按周查询四标
     * @return
     */
    List<Map<String, Object>> productWeek4();

    /**
     * 按月查询一标
     * @return
     */
    List<Map<String, Object>> productMonth1();

    /**
     * 按月查询二标
     * @return
     */
    List<Map<String, Object>> productMonth2();

    /**
     * 按月查询三标
     * @return
     */
    List<Map<String, Object>> productMonth3();

    /**
     * 按月查询四标
     * @return
     */
    List<Map<String, Object>> productMonth4();

    List<Map<String, Object>> productYear1();
    List<Map<String, Object>> productYear2();
    List<Map<String, Object>> productYear3();
    List<Map<String, Object>> productYear4();

    /**
     * 各标段张拉梁片次数对比
     * @return
     */
    List<Map<String, Object>> tensionBeamNoCount();

    /**
     * 1234标实验室设备在线数
     * @return
     */
    List<Map<String, Object>> labDeviceOnlineNumCount();

    /**
     * 1234标实验室设备在线时长
     * @return
     */
    List<Map<String, Object>> labDeviceOnlineTimeCount();

    /**
     * 1234标拌合站设备在线数
     * @return
     */
    List<Map<String, Object>> mixDeviceOnlineNumCount();

    /**
     * 1234标实验室设备在线时长
     * @return
     */
    List<Map<String, Object>> mixDeviceOnlineTimeCount();

    /**
     * 各标段试验合格次数
     * @return
     */
    List<Map<String, Object>> labEligibleCountY1();
    List<Map<String, Object>> labEligibleCountY2();
    List<Map<String, Object>> labEligibleCountY3();
    List<Map<String, Object>> labEligibleCountY4();

    /**
     * 各标段试验不合格次数
     * @return
     */
    List<Map<String, Object>> labEligibleCountN1();
    List<Map<String, Object>> labEligibleCountN2();
    List<Map<String, Object>> labEligibleCountN3();
    List<Map<String, Object>> labEligibleCountN4();

    List<Map<String, Object>> selectLabList1();
    List<Map<String, Object>> selectLabList2();
    List<Map<String, Object>> selectLabList3();
    List<Map<String, Object>> selectLabList4();

    List<Map<String, Object>> productWeek0(@Param("deptId") String deptId);

    List<Map<String, Object>> productMonth0(@Param("deptId") String deptId);

    List<Map<String, Object>> productYear0(@Param("deptId") String deptId);

    List<Map<String, Object>> productTotal0(@Param("deptId") String deptId);

    List<Map<String, Object>> selectLabList0(@Param("list") List<String> deptIdList);

    List<Map<String, Object>> tensionBeamNoCount0(@Param("list") List<String> deptIdList);

    List<Map<String, Object>> selectLabList(@Param("deptId") String deptId);

    List<Map<String, Object>> labDeviceOnlineNumCount0(@Param("list") List<String> deptIdList);

    List<Map<String, Object>> labDeviceOnlineTimeCount0(@Param("list") List<String> deptIdList);

    List<Map<String, Object>> mixDeviceOnlineNumCount0(@Param("list") List<String> deptIdList);

    List<Map<String, Object>> mixDeviceOnlineTimeCount0(@Param("list") List<String> deptIdList);

    /**
     * 新首页-接入设备及预警统计
     * @return
     */
    List<Map<String,Object>> newCountLab(@Param("list") List<String> deptIdList, @Param("name") String name);

    List<Map<String, Object>> newCountMix(@Param("list") List<String> deptIdList, @Param("name") String name);

    List<Map<String, Object>> newCountTension(@Param("list") List<String> deptIdList, @Param("name") String name);

    List<Map<String, Object>> newCountGrouting(@Param("list") List<String> deptIdList, @Param("name") String name);

    // 获取未处置的 张拉 压浆 试验 混凝土 水稳 沥青 的预警通知数量
    List<Integer> todoCount(@Param("disposalStatus") Integer disposalStatus, @Param("deptId") Long deptId);

    List<Integer> tudoDisposal(@Param("disposalStatus") Integer disposalStatus, @Param("userId") Long userId);


}
